package com.crm.model.jdao;

import java.util.List;

import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.domain.Specification;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.CrudRepository;

import com.crm.model.pojo.Competitor;
import com.crm.model.pojo.Competitor;
import com.crm.model.pojo.Solution;

public interface ICompetitorDAO extends CrudRepository<Competitor,Integer>  {
	
	/**
	 * 带条件的分页，查询所有竞争对手
	 * @param <T>
	 * @return
	 * 
	 */
 
 Page<Competitor> findAll(Specification<Competitor> spec,Pageable pageable);
  
  /**
   * 统计对象个数
   */
  long count();
  
  /**
   * 根据id查询竞争对手
   * @param salId
   * @return
   */
  Competitor findByComId(Integer comId);
  


}
